package com.example.tests;

import java.util.Set;

import org.testng.annotations.Test;

public class GroupCreationTestOne extends TestBase {

	@Test
	public void testGroupWithEmptyDataCanBeCreated() throws Exception {
		GroupObjectClass emptyDataGroup = new GroupObjectClass()
		.setName("").setHeader("").setFooter("");
		app.getGroupHelper().creationGroup(emptyDataGroup);
	}

	@Test
	public void validGroupCanBeCraetedTest() throws Exception {
		GroupObjectClass validDataGroup = new GroupObjectClass()
		.setName("Group name:").setHeader("Group header (Logo):").setFooter("Group footer (Comment):");
		
		Set<GroupObjectClass> oldList = app.getGroupHelper().getGroups();
//		action
		app.getGroupHelper().creationGroup(validDataGroup);
//		verification
		Set<GroupObjectClass> newList = app.getGroupHelper().getGroups();
		verifyGroupAdded(oldList, validDataGroup, newList );
	}

	private void verifyGroupAdded(Set<GroupObjectClass> oldList,
			GroupObjectClass validDataGroup, Set<GroupObjectClass> newList) {
		// TODO Auto-generated method stub
		
	}

}



